package com.ruoyi.base.service.impl;

import com.ruoyi.base.domain.BBank;
import com.ruoyi.base.mapper.BBankMapper;
import com.ruoyi.base.service.IBBankService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 题库Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-03-24
 */
@Service
public class BBankServiceImpl implements IBBankService
{
    @Autowired
    private BBankMapper bBankMapper;

    /**
     * 查询题库
     * 
     * @param bankId 题库主键
     * @return 题库
     */
    @Override
    public BBank selectBBankByBankId(Long bankId)
    {
        return bBankMapper.selectBBankByBankId(bankId);
    }

    /**
     * 查询题库列表
     * 
     * @param bBank 题库
     * @return 题库
     */
    @Override
    public List<BBank> selectBBankList(BBank bBank)
    {
        return bBankMapper.selectBBankList(bBank);
    }

    /**
     * 新增题库
     * 
     * @param bBank 题库
     * @return 结果
     */
    @Override
    public int insertBBank(BBank bBank)
    {
        return bBankMapper.insertBBank(bBank);
    }

    /**
     * 修改题库
     * 
     * @param bBank 题库
     * @return 结果
     */
    @Override
    public int updateBBank(BBank bBank)
    {
        return bBankMapper.updateBBank(bBank);
    }

    /**
     * 批量删除题库
     * 
     * @param bankIds 需要删除的题库主键
     * @return 结果
     */
    @Override
    public int deleteBBankByBankIds(Long[] bankIds)
    {
        return bBankMapper.deleteBBankByBankIds(bankIds);
    }

    /**
     * 删除题库信息
     * 
     * @param bankId 题库主键
     * @return 结果
     */
    @Override
    public int deleteBBankByBankId(Long bankId)
    {
        return bBankMapper.deleteBBankByBankId(bankId);
    }
}
